package top.xxyu.netty.server;

import io.netty.bootstrap.ServerBootstrap;
import io.netty.channel.Channel;
import io.netty.channel.ChannelInitializer;
import io.netty.channel.nio.NioEventLoopGroup;
import io.netty.channel.socket.SocketChannel;
import io.netty.channel.socket.nio.NioServerSocketChannel;

public class Server {

	public void run(){
		//用户处理服务器接口客户端连接
		NioEventLoopGroup bossGroup = new NioEventLoopGroup();
		//进行网络通信读写
		NioEventLoopGroup workerGroup = new NioEventLoopGroup();
		//辅助工具类，用户服务器通道的一系列配置	
		ServerBootstrap serverBootstrap = new ServerBootstrap();
		serverBootstrap.group(bossGroup, workerGroup)
			.channel(NioServerSocketChannel.class)
			.childHandler(new ChannelInitializer<SocketChannel>() {

			@Override
			protected void initChannel(SocketChannel socketChannel) throws Exception {
				// TODO Auto-generated method stub
				
			}

			
		});
	}

}
